package com.soa.zuul.entity;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.Id;
import javax.persistence.Table;
import org.hibernate.annotations.GenericGenerator;

/**
 * GatewayHttpApi entity. @author MyEclipse Persistence Tools
 */
@Entity
@Table(name = "gateway_http_api")
public class GatewayHttpApi implements java.io.Serializable {

	// Fields
	private String id;
	private String path;
	private String serviceId;
	private String url;
	private Boolean retryable;
	private Boolean enabled;
	private Boolean stripPrefix;
	private String apiName;
	private Integer sorts;
	private String isAuth;
	private String type;
	private String contact;
	private String whiteList;
	private String isOpenWhiteList;
	private String proxyType;
	// Constructors

	/** default constructor */
	public GatewayHttpApi() {
	}

	/** minimal constructor */
	public GatewayHttpApi(String path, Boolean enabled) {
		this.path = path;
		this.enabled = enabled;
	}

	/** full constructor */
	public GatewayHttpApi(String path, String serviceId, String url,
			Boolean retryable, Boolean enabled, Boolean stripPrefix,
			String apiName) {
		this.path = path;
		this.serviceId = serviceId;
		this.url = url;
		this.retryable = retryable;
		this.enabled = enabled;
		this.stripPrefix = stripPrefix;
		this.apiName = apiName;
	}

	// Property accessors
	@Id
	@Column(name = "id", nullable = false, length = 50)
	@GenericGenerator(name = "uuidGener", strategy = "uuid")
	@GeneratedValue(generator = "uuidGener")
	public String getId() {
		return this.id;
	}

	public void setId(String id) {
		this.id = id;
	}

	@Column(name = "path", nullable = false)
	public String getPath() {
		return this.path;
	}

	public void setPath(String path) {
		this.path = path;
	}

	@Column(name = "service_id", length = 50)
	public String getServiceId() {
		return this.serviceId;
	}

	public void setServiceId(String serviceId) {
		this.serviceId = serviceId;
	}

	@Column(name = "url")
	public String getUrl() {
		return this.url;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	@Column(name = "retryable")
	public Boolean getRetryable() {
		return this.retryable;
	}

	public void setRetryable(Boolean retryable) {
		this.retryable = retryable;
	}

	@Column(name = "enabled", nullable = false)
	public Boolean getEnabled() {
		return this.enabled;
	}

	public void setEnabled(Boolean enabled) {
		this.enabled = enabled;
	}

	@Column(name = "strip_prefix")
	public Boolean getStripPrefix() {
		return this.stripPrefix;
	}

	public void setStripPrefix(Boolean stripPrefix) {
		this.stripPrefix = stripPrefix;
	}

	@Column(name = "api_name")
	public String getApiName() {
		return this.apiName;
	}

	public void setApiName(String apiName) {
		this.apiName = apiName;
	}

	
	@Column(name = "sorts")
	public Integer getSorts() {
		return sorts;
	}

	public void setSorts(Integer sorts) {
		this.sorts = sorts;
	}
	@Column(name = "is_auth")
	public String getIsAuth() {
		return isAuth;
	}
	public void setIsAuth(String isAuth) {
		this.isAuth = isAuth;
	}
	@Column(name = "contact")
	public String getContact() {
		return contact;
	}

	public void setContact(String contact) {
		this.contact = contact;
	}
	@Column(name = "type")
	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}
	@Column(name = "white_list")
	public String getWhiteList() {
		return whiteList;
	}

	public void setWhiteList(String whiteList) {
		this.whiteList = whiteList;
	}

	@Column(name = "is_open_white_list")
	public String getIsOpenWhiteList() {
		return isOpenWhiteList;
	}

	public void setIsOpenWhiteList(String isOpenWhiteList) {
		this.isOpenWhiteList = isOpenWhiteList;
	}
	@Column(name = "proxy_type")
	public String getProxyType() {
		return proxyType;
	}

	public void setProxyType(String proxyType) {
		this.proxyType = proxyType;
	}
}